home *** CD-ROM | disk | FTP | other *** search
/ Compendium Deluxe 2 / LSD and 17bit Compendium Deluxe - Volume II.iso / a / prog / misc / date.lha / Date / Oberon / txt / Date.def < prev    next >
Text File  |  1994-08-11  |  4KB  |  74 lines

  1. DEFINITION Date;
  2.  
  3. TYPE
  4.   Weekdays = SHORTINT;
  5.  
  6. CONST
  7.   dayerr = 0;
  8.   Monday = 1;
  9.   Tuesday = 2;
  10.   Wednesday = 3;
  11.   Thursday = 4;
  12.   Friday = 5;
  13.   Saturday = 6;
  14.   Sunday = 7;
  15.  
  16. PROCEDURE JulianLeapYear(year: INTEGER): BOOLEAN;
  17. PROCEDURE GregorianLeapYear(year: INTEGER): BOOLEAN;
  18. PROCEDURE HeisLeapYear(year: INTEGER): BOOLEAN;
  19. PROCEDURE JulianMonthDays(month: SHORTINT; year: INTEGER): SHORTINT;
  20. PROCEDURE GregorianMonthDays(month: SHORTINT; year: INTEGER): SHORTINT;
  21. PROCEDURE HeisMonthDays(month: SHORTINT; year: INTEGER): SHORTINT;
  22. PROCEDURE JulianYearDays(year: INTEGER): INTEGER;
  23. PROCEDURE GregorianYearDays(year: INTEGER): INTEGER;
  24. PROCEDURE HeisYearDays(year: INTEGER): INTEGER;
  25. PROCEDURE JulianDaySmaller(day1, month1: SHORTINT; year1: INTEGER; day2, month2: SHORTINT; year2: INTEGER): BOOLEAN;
  26. PROCEDURE GregorianDaySmaller(day1, month1: SHORTINT; year1: INTEGER; day2, month2: SHORTINT; year2: INTEGER): BOOLEAN;
  27. PROCEDURE HeisDaySmaller(day1, month1: SHORTINT; year1: INTEGER; day2, month2: SHORTINT; year2: INTEGER): BOOLEAN;
  28. PROCEDURE JulianDayGreater(day1, month1: SHORTINT; year1: INTEGER; day2, month2: SHORTINT; year2: INTEGER): BOOLEAN;
  29. PROCEDURE GregorianDayGreater(day1, month1: SHORTINT; year1: INTEGER; day2, month2: SHORTINT; year2: INTEGER): BOOLEAN;
  30. PROCEDURE HeisDayGreater(day1, month1: SHORTINT; year1: INTEGER; day2, month2: SHORTINT; year2: INTEGER): BOOLEAN;
  31. PROCEDURE JulianDayDiff(day1, month1: SHORTINT; year1: INTEGER; day2, month2: SHORTINT; year2: INTEGER): LONGINT;
  32. PROCEDURE GregorianDayDiff(day1, month1: SHORTINT; year1: INTEGER; day2, month2: SHORTINT; year2: INTEGER): LONGINT;
  33. PROCEDURE HeisDayDiff(day1, month1: SHORTINT; year1: INTEGER; day2, month2: SHORTINT; year2: INTEGER): LONGINT;
  34. PROCEDURE JulianWeekday(day, month: SHORTINT; year: INTEGER): Weekdays;
  35. PROCEDURE GregorianWeekday(day, month: SHORTINT; year: INTEGER): Weekdays;
  36. PROCEDURE HeisWeekday(day, month: SHORTINT; year: INTEGER): Weekdays;
  37. PROCEDURE JulianDaysBeforeWeekday(day, month: SHORTINT; year: INTEGER; weekday: Weekdays): SHORTINT;
  38. PROCEDURE GregorianDaysBeforeWeekday(day, month: SHORTINT; year: INTEGER; weekday: Weekdays): SHORTINT;
  39. PROCEDURE HeisDaysBeforeWeekday(day, month: SHORTINT; year: INTEGER; weekday: Weekdays): SHORTINT;
  40. PROCEDURE JulianDaysAfterWeekday(day, month: SHORTINT; year: INTEGER; weekday: Weekdays): SHORTINT;
  41. PROCEDURE GregorianDaysAfterWeekday(day, month: SHORTINT; year: INTEGER; weekday: Weekdays): SHORTINT;
  42. PROCEDURE HeisDaysAfterWeekday(day, month: SHORTINT; year: INTEGER; weekday: Weekdays): SHORTINT;
  43. PROCEDURE JulianDiffDate(day, month: SHORTINT; year, days: INTEGER; VAR dday, dmonth: SHORTINT; VAR dyear: INTEGER);
  44. PROCEDURE GregorianDiffDate(day, month: SHORTINT; year, days: INTEGER; VAR dday, dmonth: SHORTINT; VAR dyear: INTEGER);
  45. PROCEDURE HeisDiffDate(day, month: SHORTINT; year, days: INTEGER; VAR dday, dmonth: SHORTINT; VAR dyear: INTEGER);
  46. PROCEDURE JYearToScaliger(year: INTEGER): INTEGER;
  47. PROCEDURE GYearToScaliger(year: INTEGER): INTEGER;
  48. PROCEDURE HYearToScaliger(year: INTEGER): INTEGER;
  49. PROCEDURE ScaligerYearToJ(syear: INTEGER): INTEGER;
  50. PROCEDURE ScaligerYearToG(syear: INTEGER): INTEGER;
  51. PROCEDURE ScaligerYearToH(syear: INTEGER): INTEGER;
  52. PROCEDURE JSYearToJD(syear: INTEGER): LONGINT;
  53. PROCEDURE GSYearToJD(syear: INTEGER): LONGINT;
  54. PROCEDURE HSYearToJD(syear: INTEGER): LONGINT;
  55. PROCEDURE JDtoMJD(jd: LONGINT): LONGINT;
  56. PROCEDURE MJDtoJD(mjd: LONGINT): LONGINT;
  57. PROCEDURE JulianToJD(day, month: SHORTINT; year: INTEGER): LONGINT;
  58. PROCEDURE GregorianToJD(day, month: SHORTINT; year: INTEGER): LONGINT;
  59. PROCEDURE HeisToJD(day, month: SHORTINT; year: INTEGER): LONGINT;
  60. PROCEDURE TimeToJD(hour, min, sec: SHORTINT): REAL;
  61. PROCEDURE JDToTime(jd: REAL; VAR rhour, rmin, rsec: SHORTINT);
  62. PROCEDURE GregorianMoonAge(day, month: SHORTINT; year: INTEGER): SHORTINT;
  63. PROCEDURE GregorianEaster(year: INTEGER; VAR dday, dmonth: SHORTINT);
  64. PROCEDURE TimeZoneFactor(degree: SHORTINT): SHORTINT;
  65. PROCEDURE LMT(secs: LONGINT; meridiandegree, posdegree: REAL): LONGINT;
  66. PROCEDURE TimeToSec(hour, min, sec: SHORTINT): LONGINT;
  67. PROCEDURE SecToTime(secs: LONGINT; VAR hour, min, sec: SHORTINT);
  68. PROCEDURE JulianWeek(day, month: SHORTINT; year: INTEGER): SHORTINT;
  69. PROCEDURE GregorianWeek(day, month: SHORTINT; year: INTEGER): SHORTINT;
  70. PROCEDURE HeisWeek(day, month: SHORTINT; year: INTEGER): SHORTINT;
  71.  
  72. END Date.
  73.  
  74.